home *** CD-ROM | disk | FTP | other *** search
/ Aminet 28 / Aminet 28 (1998)(GTI - Schatztruhe)[!][Dec 1998].iso / Aminet / dev / src / GLperf3.12-src.lha / GLperf / Makefile.aos < prev    next >
Encoding:
Makefile  |  1998-09-20  |  7.1 KB  |  260 lines

  1. #  (c) Copyright 1996, Silicon Graphics, Inc.
  2. #  ALL RIGHTS RESERVED
  3. #  Permission to use, copy, modify, and distribute this software for
  4. #  any purpose and without fee is hereby granted, provided that the above
  5. #  copyright notice appear in all copies and that both the copyright notice
  6. #  and this permission notice appear in supporting documentation, and that
  7. #  the name of Silicon Graphics, Inc. not be used in advertising
  8. #  or publicity pertaining to distribution of the software without specific,
  9. #  written prior permission.
  10. #  THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS"
  11. #  AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE,
  12. #  INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR
  13. #  FITNESS FOR A PARTICULAR PURPOSE.  IN NO EVENT SHALL SILICON
  14. #  GRAPHICS, INC.  BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT,
  15. #  SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY
  16. #  KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION,
  17. #  LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF
  18. #  THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC.  HAS BEEN
  19. #  ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON
  20. #  ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE
  21. #  POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
  22. #  US Government Users Restricted Rights
  23. #  Use, duplication, or disclosure by the Government is subject to
  24. #  restrictions set forth in FAR 52.227.19(c)(2) or subparagraph
  25. #  (c)(1)(ii) of the Rights in Technical Data and Computer Software
  26. #  clause at DFARS 252.227-7013 and/or in similar or successor
  27. #  clauses in the FAR or the DOD or NASA FAR Supplement.
  28. #  Unpublished-- rights reserved under the copyright laws of the
  29. #  United States.  Contractor/manufacturer is Silicon Graphics,
  30. #  Inc., 2011 N.  Shoreline Blvd., Mountain View, CA 94039-7311.
  31. #  Author: John Spitzer, SGI Desktop Performance Engineering
  32.  
  33. # These control the size of your executable (and the amount of
  34. # functionality that the size provides)
  35. #
  36. # FULL_VERTEX_PATHS  - Allows you to send 2d as well as 3d vertex
  37. #                      data (without this, you'll only get 3d)
  38. # FULL_RASTERPOS_PATHS  - Allows you to send 2d as well as 3d raster position
  39. #                      data (without this, you'll only get 3d)
  40. # FULL_TEXTURE_PATHS - Allows you to use 1d as well as 2d textures
  41. #                      (without, you'll only get 2d)
  42. # FULL_COLOR_PATHS   - Allows you to use RGBA as well as RGB data
  43. #                      (without, you'll only get RGB)
  44. # FULL_FUNCPTR_PATHS - Allows you to use function ptrs in the inner loop
  45. #                      (without, you won't be able to use them)
  46. # FULL_UNROLL_PATHS  - Allows you to unroll in the inner loop (up to 8)
  47. #                      (without, you won't be able to unroll at all)
  48. #
  49.  
  50. include MakeAdd
  51.  
  52. PATHS = \
  53.     -DFULL_COLOR_PATHS \
  54.     -DFULL_VERTEX_PATHS \
  55.     -DFULL_RASTERPOS_PATHS \
  56.     -DFULL_TEXTURE_PATHS
  57.  
  58. help:
  59.     echo "Need to choose a config to compile: amiga"
  60.  
  61. amiga:
  62.     rm -f MakeAdd
  63.     echo "# Nothing" > MakeAdd
  64.     make \
  65.     MAKE="make" \
  66.     LEX="flex -l" \
  67.     YACC="bison -y" \
  68.     CC="gcc -c" \
  69.     E="" \
  70.     O=".o" \
  71.     LINK="gcc" \
  72.     CCFLAGS="-s -v -O3 -m68030 -m68881 -fno-float-store -ffunction-cse -fpeephole -ffast-math -fomit-frame-pointer -fstrength-reduce -frerun-cse-after-loop -frerun-loop-opt -fschedule-insns -fschedule-insns2 -fmove-all-movables -freg-struct-return -freduce-all-givs -fforce-addr -mbitfield" \
  73.     AUX_DIR="" \
  74.     AUX_LIB="" \
  75.     ENV_C="EnvAOS.c" \
  76.     INCLUDES="" \
  77.     LIBS="-L/img/Mesa-3.0/lib -L. -lperf -lm -lMesaGLaux -lMesaGLtk -lMesaGLu -lMesaGL" \
  78.     LFLAGS="-s -m68030 -m68881 -o " \
  79.     GL_H="/ade/os-include/gl/gl.h" \
  80.     GLU_H="/ade/os-include/gl/glu.h" \
  81.     LEX_YY="lex.yy" \
  82.     Y_TAB="y.tab" \
  83.     LEX_YACC="lex.yy.c y.tab.c y.tab.h" \
  84.     RM="rm -f" \
  85.     CP="cp" \
  86.     PERF_LIB="libperf.a" \
  87.     MAKELIB="ar rv " \
  88.     -f Makefile.aos GLperf
  89.  
  90. # Placeholder definitions (not actually used, don't worry)
  91. PERF_LIB = libperf.a
  92. MAKELIB = ar rv 
  93. MAKE = make
  94. LEX = lex
  95. YACC = yacc
  96. CC = cc -c
  97. E = 
  98. O = .o
  99. LINK = cc
  100. CCFLAGS = -O -DXWINDOWS
  101. AUX_DIR = libaux
  102. AUX_LIB = libaux.a
  103. ENV_C = EnvSGI.c
  104. INCLUDES = -I$(AUX_DIR) -I/usr/include/GL
  105. LIBS = -L. -L$(AUX_DIR) -lperf -lm -laux -lGLU -lGL -lX11 -lXext
  106. LFLAGS = $(CFLAGS) -o
  107. GL_H = /usr/include/GL/gl.h
  108. GLU_H = /usr/include/GL/glu.h
  109. LEX_YY = lex.yy
  110. Y_TAB = y.tab
  111. LEX_YACC = lex.yy.c y.tab.c y.tab.h
  112. RM=rm -f
  113. COPY=cp
  114.  
  115. #
  116. # You shouldn't have to change anything past here
  117. #
  118.  
  119. CMDS = GLperf$E
  120.  
  121. CFLAGS = $(CCFLAGS) $(INCLUDES) $(PATHS)
  122.  
  123. include Objs
  124.  
  125. CFLAGS = $(CCFLAGS) $(INCLUDES) $(PATHS)
  126.  
  127. $(CMDS): $(PERF_LIB) $(CMDS)$O
  128.     $(LINK) $(LFLAGS)$@ $(CMDS)$O $(LIBS)
  129.  
  130. GENERATE = Bitmap.x Clear.x CopyPix.x DrawPix.x ReadPix.x TexBind.x \
  131.            TexCopy.x TexLoad.x Text.x Xform.x VertA11.x VertexA.x
  132. GENEXE  = $(GENERATE:.x=G$E) VertexG$E
  133. GENCSRC = $(GENERATE:.x=F.c) Vert??F.c
  134. GENHDRS = $(GENERATE:.x=X.h) Vert??F.h
  135. GENDIRT = $(GENEXE) $(GENCSRC) $(GENHDRS)
  136.  
  137. TABSTUFF = AttrTab.h PropTab.h TestTab.h ./Cat$E ./MakeTab$E
  138. CLEANFILES = *$O GLperf$E $(LEX_YACC) $(TABSTUFF) $(GENDIRT) $(PERF_LIB)
  139.  
  140. clean:  
  141.     $(RM) $(CLEANFILES)
  142.  
  143. #
  144. # These rules show how the libraries are built
  145. #
  146.  
  147. $(PERF_LIB): $(OBJS)
  148.     $(MAKELIB) $@ $?
  149.  
  150. #
  151. # These rules show how the generators create their files
  152. #
  153.  
  154. #BitmapX.h BitmapF.c: BitmapG$E
  155. #    BitmapG$E
  156.  
  157. #ClearX.h ClearF.c: ClearG$E
  158. #    ClearG$E
  159.  
  160. #CopyPixX.h CopyPixF.c: CopyPixG$E
  161. #    CopyPixG$E
  162.  
  163. #DrawPixX.h DrawPixF.c: DrawPixG$E
  164. #    DrawPixG$E
  165.  
  166. #ReadPixX.h ReadPixF.c: ReadPixG$E
  167. #    ReadPixG$E
  168.  
  169. #TexBindX.h TexBindF.c: TexBindG$E
  170. #    TexBindG$E
  171.  
  172. #TexCopyX.h TexCopyF.c: TexCopyG$E
  173. #    TexCopyG$E
  174.  
  175. #TexLoadX.h TexLoadF.c: TexLoadG$E
  176. #    TexLoadG$E
  177.  
  178. #TextX.h TextF.c: TextG$E
  179. #    TextG$E
  180.  
  181. #VertA11X.h VertA11F.c: VertA11G$E
  182. #    VertA11G$E
  183.  
  184. #VertexAX.h VertexAF.c: VertexAG$E
  185. #    VertexAG$E
  186.  
  187. #VertexX.h \
  188. #Vert00F.h Vert00F.c \
  189. #Vert01F.h Vert01F.c \
  190. #Vert02F.h Vert02F.c \
  191. #Vert03F.h Vert03F.c \
  192. #Vert04F.h Vert04F.c \
  193. #Vert05F.h Vert05F.c \
  194. #Vert08F.h Vert08F.c \
  195. #Vert09F.h Vert09F.c \
  196. #Vert10F.h Vert10F.c \
  197. #Vert11F.h Vert11F.c \
  198. #Vert12F.h Vert12F.c \
  199. #Vert13F.h Vert13F.c \
  200. #Vert16F.h Vert16F.c \
  201. #Vert17F.h Vert17F.c \
  202. #Vert18F.h Vert18F.c \
  203. #Vert19F.h Vert19F.c \
  204. #Vert20F.h Vert20F.c \
  205. #Vert21F.h Vert21F.c: VertexG$E
  206. #    VertexG$E
  207.  
  208. #XformX.h XformF.c: XformG$E
  209. #    XformG$E
  210.  
  211. #
  212. # These rules show how the other source files are created
  213. #
  214.  
  215. #Env.c:
  216. #    $(RM) Env.c
  217. #    $(CP) $(ENV_C) Env.c
  218.  
  219. #PropTab.h: PropName.h ./Cat$E ./MakeTab$E
  220. #    ./Cat$E PropName.h | ./MakeTab$E Properties > PropTab.h
  221.  
  222. #TestTab.h: TestName.h ./Cat$E ./MakeTab$E
  223. #    ./Cat$E TestName.h | ./MakeTab$E Tests > TestTab.h
  224.  
  225. #AttrTab.h: AttrName.h $(GL_H) $(GLU_H) ./Cat$E ./MakeTab$E
  226. #    ./Cat$E $(GL_H) $(GLU_H) AttrName.h | ./MakeTab$E Attributes > AttrTab.h
  227.  
  228. $(LEX_YY).c: Parse.l PropTab.h TestTab.h AttrTab.h
  229.     $(LEX) Parse.l
  230.  
  231. $(Y_TAB).c $(Y_TAB).h: Parse.y $(LEX_YY).c
  232.     $(YACC) -d Parse.y
  233.  
  234. #
  235. # These rules show the dependencies of object files on source files
  236. #
  237.  
  238. include Depends
  239.  
  240. #
  241. # This rule shows how the source files are created
  242. #
  243.  
  244. .c$O:
  245.     $(CC) $(CFLAGS) $<
  246.  
  247. #
  248. # This rule shows how the file generators are created
  249. #
  250.  
  251. .c$E $(GENEXE):
  252.     $(CC) $(CFLAGS) $@.c
  253.     $(LINK) $(LFLAGS)$@ $@$O
  254.  
  255.